#env = Environment(CC = 'g++')
import os
def gen_exec_file(file):
    return os.path.splitext(file)[0]+'.out'

env = Environment()
env['CCFLAGS'] = '-g'
env['CXXFLAGS'] = '-g'
env['LIBS']=['pthread']
env.Append(CXXFLAGS=['-Ddebug','-Wall'])

def build_out(src_file):
    src = Split(src_file)
    target = gen_exec_file(src[0])
    env.Program(target, src)

build_out('3_线程传递_地址_引用参数.cc')
build_out('5_thread_线程_类的成员函数.cc')
build_out('5.1_thread_线程_类的成员函数.cc')
build_out('6_多线程_每个线程cpu消耗统计.cc')
